<?php

namespace App\Http\Controllers\Admin\System;

use App\Models\System\Config;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;

class ConfigController extends Controller
{
   /**
    * Display a listing of the resource.
    *
    * @return \Illuminate\Http\Response
    */
   public function index()
   {
      $id = 1;
      $config = Config::find($id);
      return response()->json($config);
   }

   /**
    * Update the specified resource in storage.
    *
    * @param \Illuminate\Http\Request $request
    * @param int $id
    * @return \Illuminate\Http\Response
    */
   public function update(Request $request, $id)
   {
      $config = Config::find($id);
      $config->update($request->all());
   }

}
